// function MBSuccess(data) {
//   return {
//     ResponseCode: 'AAAAAAA',
//     ResponseMsg: '',
//     ...data
//   }
// }

// function MBError({ ResponseCode = 'error', ResponseMsg = 'error' } = {}) {
//   return {
//     ResponseCode: ResponseCode || 'error',
//     ResponseMsg: ResponseMsg || ''
//   }
// }

function ENTSuccess(response) {
  return {
    code: 'AAAAAA',
    msg: '',
    response
  }
}

// function ENTError(code, msg) {
//   return {
//     code: code || 'error',
//     msg: msg || '接口异常！'
//   }
// }

export default {
  QryProjectInformation111: {
    code: 'AAAAAA',
    msg: '',
    response: {
      news: [
        {
          index: 'NEWS111'
        }
      ]
    }
  },
  QryProjectInformation222: {
    code: 'AAAAAA',
    msg: '',
    response: {
      news: [
        {
          index: 'NEWS222'
        }
      ]
    }
  },
  'POST /gw/wx_miniapp/QryProjectInformation.do'(req, res) {
    res.json(
      ENTSuccess({
        news: [
          {
            index: 'NEWS1',
            newsList: [
              '民生银行是较早进行投行业务专业化经营的商业银行，早在2013年就成立了总行一级部门投资银行部，专门经营发债、资产证券化、并购、结构化融资、资本市场业务，并在业内率先提出 "商行+投行"发展理念。',
              '2018年，成立投行直营事业部（二级部），专营投行直营业务，包括投贷联动、PRE-IPO投资、定增直投、可转债、权益级REITs投资等，并在银行业创新实施去行政化的MD职衔体制。'
            ]
          }
        ]
      })
    )
  },
  'POST /gw/wx_miniapp/QryHotProjects.do'(req, res) {
    res.json(
      ENTSuccess({
        resultList: [
          {
            optionId: '001',
            optionName: '资本市场业务'
          },
          {
            optionId: '006',
            optionName: '债券类'
          },
          {
            optionId: '007',
            optionName: '房地产类'
          },
          {
            optionId: '008',
            optionName: '城市开发及基础设施类'
          },
          {
            optionId: '009',
            optionName: '资产证券化-ABS'
          }
        ]
      })
    )
  },
  'POST /gw/wx_miniapp/QryProjectsTypes.do'(req, res) {
    res.json(
      ENTSuccess({
        resultList: [
          {
            optionId: '001',
            optionName: '资本市场业务'
          },
          {
            optionId: '002',
            optionName: '并购业务'
          },
          {
            optionId: '003',
            optionName: '股权类'
          },
          {
            optionId: '004',
            optionName: '银团类'
          },
          {
            optionId: '005',
            optionName: '租赁类'
          },
          {
            optionId: '006',
            optionName: '债券类'
          },
          {
            optionId: '007',
            optionName: '房地产类'
          },
          {
            optionId: '008',
            optionName: '城市开发及基础设施类'
          },
          {
            optionId: '009',
            optionName: '资产证券化-ABS'
          },
          {
            optionId: '010',
            optionName: '资产证券化-ABN'
          },
          {
            optionId: '011',
            optionName: '北金所类'
          },
          {
            optionId: '012',
            optionName: '其他'
          }
        ]
      })
    )
  },
  'POST /gw/wx_miniapp/QryProjectsRegion.do'(req, res) {
    res.json(
      ENTSuccess({
        resultList: [
          {
            optionGroup: '华东地区',
            optionGroupList: [
              {
                optionGroup: '华东地区',
                optionId: '001',
                optionName: '上海'
              },
              {
                optionGroup: '华东地区',
                optionId: '002',
                optionName: '江苏'
              },
              {
                optionGroup: '华东地区',
                optionId: '003',
                optionName: '浙江'
              },
              {
                optionGroup: '华东地区',
                optionId: '004',
                optionName: '山东'
              }
            ]
          },
          {
            optionGroup: '华南地区',
            optionGroupList: [
              {
                optionGroup: '华南地区',
                optionId: '005',
                optionName: '广东'
              },
              {
                optionGroup: '华南地区',
                optionId: '006',
                optionName: '福建'
              },
              {
                optionGroup: '华南地区',
                optionId: '007',
                optionName: '广西'
              },
              {
                optionGroup: '华南地区',
                optionId: '008',
                optionName: '海南'
              }
            ]
          },
          {
            optionGroup: '华北地区',
            optionGroupList: [
              {
                optionGroup: '华北地区',
                optionId: '009',
                optionName: '北京'
              },
              {
                optionGroup: '华北地区',
                optionId: '010',
                optionName: '天津'
              },
              {
                optionGroup: '华北地区',
                optionId: '011',
                optionName: '河北'
              }
            ]
          }
        ]
      })
    )
  },
  'POST /gw/wx_miniapp/QryProjectsInstitutions.do'(req, res) {
    res.json(
      ENTSuccess({
        resultList: [
          {
            optionId: '001',
            optionName: '银行及理财子公司',
            englishName: 'Banking Institutions'
          },
          {
            optionId: '002',
            optionName: '保险及保险资管',
            englishName: 'Insurance Institutions'
          },
          {
            optionId: '003',
            optionName: '信托',
            englishName: 'Trust'
          },
          {
            optionId: '004',
            optionName: '租赁',
            englishName: 'Leasing'
          },
          {
            optionId: '005',
            optionName: '券商及资管子公司',
            englishName: 'Securities Companies'
          },
          {
            optionId: '006',
            optionName: '基金及其子公司',
            englishName: 'Funds'
          },
          {
            optionId: '007',
            optionName: '企业及其他',
            englishName: 'Enterprises & Others'
          }
        ]
      })
    )
  },
  'POST /gw/wx_miniapp/QryProjectsLists.do'(req, res) {
    const resultList = [
      {
        financingMaturity: '3',
        financingMaturityUnit: 'Y',
        financingScale: '3',
        financingScaleUnit: '亿元',
        financingSubjectRate: 'A+',
        projectId: '2020051401',
        projectName: '项目名称1很长很长很长很长很长很长很长很长很长很长',
        projectStatus: '1',
        projectType: '租赁类',
        publishDate: '2020-05-01',
        region: '广东',
        isCollect: '0'
      },
      {
        financingMaturity: '3',
        financingMaturityUnit: 'Y',
        financingScale: '4',
        financingScaleUnit: '亿元',
        financingSubjectRate: 'AAA',
        projectId: '2020051402',
        projectName: '项目名称2很长很长很长很长很长很长很长很长',
        projectStatus: '2',
        projectType: '股权类',
        publishDate: '2020-05-02',
        region: '广东',
        isCollect: '1'
      },
      {
        financingMaturity: '3',
        financingMaturityUnit: 'Y',
        financingScale: '5',
        financingScaleUnit: '亿元',
        financingSubjectRate: 'AAA',
        projectId: '2020051403',
        projectName: '项目名称3很长很长很长很长很长很长',
        projectStatus: '3',
        projectType: '股权类',
        publishDate: '2020-05-03',
        region: '广东',
        isCollect: '0'
      },
      {
        financingMaturity: '3',
        financingMaturityUnit: 'Y',
        financingScale: '6',
        financingScaleUnit: '亿元',
        financingSubjectRate: 'BB+',
        projectId: '2020051501',
        projectName: '项目名称4很长很长很长很长',
        projectStatus: '4',
        publishDate: '2020-05-03',
        region: '广东',
        isCollect: '0'
      },
      {
        financingMaturity: '3',
        financingMaturityUnit: 'Y',
        financingScale: '6',
        financingScaleUnit: '亿元',
        financingSubjectRate: 'AA',
        projectId: '2020051801',
        projectName: '项目B',
        projectStatus: '5',
        publishDate: '2020-05-04',
        region: '广东',
        isCollect: '1'
      }
    ]

    res.json(
      ENTSuccess({
        pageNo: '1',
        pageSize: '20',
        total: 5,
        resultList
      })
    )
  },
  'POST /gw/wx_miniapp/QryProjectDetail.do'(req, res) {
    res.json(
      ENTSuccess({
        isSuccess: 1,
        resultMap: {
          creditenhanceMeasure: '啊啊啊啊啊',
          financingMaturity: '3',
          financingMaturityUnit: 'Y',
          financingScale: '3',
          financingScaleUnit: '亿元',
          financingSubjectRate: 'A+',
          leaseInformation: '隐隐约约有',
          pledge: '抵押信息',
          projectId: '2020051401',
          projectName: '项目名称项目名称',
          projectStatus: '4',
          projectType: '租赁类',
          publishDate: '2020-05-01',
          region: '上海',
          projectIntro:
            '项目简介文本项目简介文本项目简介文本项目简介文本标的企业的工业机器人柔性加工系统集成和行业解决方案提供商。截止2019年3月31日，公司在手和在制订单合计为超过6亿元。公司在谈订单合计近5亿元。单一投资人份额为0.5-1亿元，合计募资2.1亿元。',
          financingSubject: '融资主体',
          repayingSource: '公司利润',
          capitalSideIncome: '待定',
          capitalUse: '用途描述文本用途描述文本用途描述文本太长则进行折行处理',
          transStructure: '融资人日常收入及担保人差额补足',
          transStructureIntro:
            '标的公司达到承诺业绩（净利润5000万元），上市公司发行股份收购基金及实际控制人团队持有的标的公司100%股权，标的公司成为上市全资子公司，基金及实际控制人团队成为上市公司股东。'
        }
      })
    )
  },
  'POST /gw/wx_miniapp/CollectProduct.do'(req, res) {
    res.json(
      ENTSuccess({
        isSuccess: 1
      })
    )
  },
  'POST /gw/wx_miniapp/QryPMMessage.do'(req, res) {
    res.json(
      ENTSuccess({
        resultMap: {
          commPersonName: '某某某',
          commBranch: '中国XX银行安定门支行',
          commPhone: '010-56880868',
          commPersonId: '000001'
        }
      })
    )
  },
  'POST /gw/wx_miniapp/QryNotesLeft.do'(req, res) {
    res.json(
      ENTSuccess({
        messageList: [
          {
            commPersonId: '0000000001',
            commPersonName: '李XX',
            createTime: '2020-05-15 16:40:57.296493',
            custId: '2200034902268',
            message: '你好啊',
            messageId: '1589531942002',
            projectId: '2020051401',
            projectName: '项目名称项目名称',
            newMessageCount: '0',
            replyCount: '1',
            orgName: '中国民生银行北京分行'
          },
          {
            commPersonId: '0000000001',
            commPersonName: '李XX',
            createTime: '2020-05-15 16:41:35.615126',
            custId: '2200034902268',
            message: '天香一双',
            messageId: '1589531980343',
            projectId: '2020051401',
            projectName: '项目名称项目名称',
            newMessageCount: '1',
            replyCount: '2',
            orgName: '中国民生银行北京分行'
          },
          {
            commPersonId: '0000000001',
            commPersonName: '李XX',
            createTime: '2020-05-15 16:42:25.013778',
            custId: '2200034902268',
            message: '无语啊',
            messageId: '1589532029740',
            projectId: '2020051401',
            projectName: '项目名称项目名称',
            newMessageCount: '2',
            replyCount: '3',
            orgName: '中国民生银行北京分行'
          },
          {
            commPersonId: '0000000001',
            commPersonName: '李XX',
            createTime: '2020-05-15 17:12:23.586023',
            custId: '2200034902268',
            message: '无1111语啊',
            messageId: '1589533828214',
            projectId: '2020051401',
            projectName: '项目名称项目名称',
            newMessageCount: '3',
            replyCount: '0',
            orgName: '中国民生银行北京分行'
          }
        ]
      })
    )
  },
  'POST /gw/wx_miniapp/QryNoteDetailList.do'(req, res) {
    res.json(
      ENTSuccess({
        resultList: [
          {
            msgList: [
              {
                commPersonId: '0175836523',
                createTime: '2020-05-30 23:29:31',
                custId: '2200034902268',
                custName: '张红',
                message:
                  '客户聊天信息客户聊天信息客户聊天信息客户聊天信息客户聊天信息客户聊天信息',
                messageId: '22000349022681590852571803',
                projectId: '15907376873800000148379',
                projectName: 'Y信托公司引入战投',
                sendFlag: '1',
                commPersonName: '张琪琪'
              },
              {
                commPersonId: '0175836523',
                createTime: '2020-05-31 23:49:31.0',
                custId: '2200034902268',
                custName: '张红',
                message:
                  '回复信息回复信息回复信息回复信息回复信息回复信息回复信息回复信息回复信息回复信息',
                messageId: '22000349022681590852571803-1',
                projectId: '15907376873800000148379',
                projectName: 'Y信托公司引入战投',
                sendFlag: '2',
                commPersonName: '张琪琪'
              },
              {
                commPersonId: '0175836523',
                createTime: '2020-05-30 23:39:31.0',
                custId: '2200034902268',
                custName: '张红',
                message:
                  '回复信息回复信息回复信息回复信息回复信息回复信息回复信息回复信息回复信息',
                messageId: '22000349022681590852571803-2',
                projectId: '15907376873800000148379',
                projectName: 'Y信托公司引入战投',
                sendFlag: '2',
                commPersonName: '张琪琪'
              }
            ]
          },
          {
            msgList: [
              {
                commPersonId: '0175836523',
                createTime: '2020-05-30 23:29:31',
                custId: '2200034902268',
                custName: '张红',
                message: '你好',
                messageId: '22000349022681590852571803',
                projectId: '15907376873800000148379',
                projectName: 'Y信托公司引入战投',
                sendFlag: '1',
                commPersonName: '张琪琪'
              },
              {
                commPersonId: '0175836523',
                createTime: '2020-05-31 23:49:31.0',
                custId: '2200034902268',
                custName: '张红',
                message: '你好qwe',
                messageId: '22000349022681590852571803-1',
                projectId: '15907376873800000148379',
                projectName: 'Y信托公司引入战投',
                sendFlag: '2',
                commPersonName: '张琪琪'
              }
            ]
          },
          {
            msgList: [
              {
                commPersonId: '0175836523',
                createTime: '2020-05-30 23:29:31',
                custId: '2200034902268',
                custName: '张红',
                message:
                  '客户聊天信息客户聊天信息客户聊天信息客户聊天信息客户聊天信息客户聊天信息',
                messageId: '22000349022681590852571803',
                projectId: '15907376873800000148379',
                projectName: 'Y信托公司引入战投',
                sendFlag: '1',
                commPersonName: '张琪琪'
              },
              {
                commPersonId: '0175836523',
                createTime: '2020-05-31 23:49:31.0',
                custId: '2200034902268',
                custName: '张红',
                message:
                  '回复信息回复信息回复信息回复信息回复信息回复信息回复信息回复信息回复信息回复信息',
                messageId: '22000349022681590852571803-1',
                projectId: '15907376873800000148379',
                projectName: 'Y信托公司引入战投',
                sendFlag: '2',
                commPersonName: '张琪琪'
              },
              {
                commPersonId: '0175836523',
                createTime: '2020-05-30 23:39:31.0',
                custId: '2200034902268',
                custName: '张红',
                message:
                  '回复信息回复信息回复信息回复信息回复信息回复信息回复信息回复信息回复信息',
                messageId: '22000349022681590852571803-2',
                projectId: '15907376873800000148379',
                projectName: 'Y信托公司引入战投',
                sendFlag: '2',
                commPersonName: '张琪琪'
              }
            ]
          },
          {
            msgList: [
              {
                commPersonId: '0175836523',
                createTime: '2020-05-30 23:29:31',
                custId: '2200034902268',
                custName: '张红',
                message:
                  '客户聊天信息客户聊天信息客户聊天信息客户聊天信息客户聊天信息客户聊天信息',
                messageId: '22000349022681590852571803',
                projectId: '15907376873800000148379',
                projectName: 'Y信托公司引入战投',
                sendFlag: '1',
                commPersonName: '张琪琪'
              },
              {
                commPersonId: '0175836523',
                createTime: '2020-05-31 23:49:31.0',
                custId: '2200034902268',
                custName: '张红',
                message:
                  '回复信息回复信息回复信息回复信息回复信息回复信息回复信息回复信息回复信息回复信息',
                messageId: '22000349022681590852571803-1',
                projectId: '15907376873800000148379',
                projectName: 'Y信托公司引入战投',
                sendFlag: '2',
                commPersonName: '张琪琪'
              },
              {
                commPersonId: '0175836523',
                createTime: '2020-05-30 23:39:31.0',
                custId: '2200034902268',
                custName: '张红',
                message:
                  '回复信息回复信息回复信息回复信息回复信息回复信息回复信息回复信息回复信息',
                messageId: '22000349022681590852571803-2',
                projectId: '15907376873800000148379',
                projectName: 'Y信托公司引入战投',
                sendFlag: '2',
                commPersonName: '张琪琪'
              }
            ]
          }
        ]
      })
    )
  },
  'POST /gw/wx_miniapp/LeftNotes.do'(req, res) {
    res.json(
      ENTSuccess({
        messageList: [
          {
            commPersonId: '0000000001',
            commPersonName: '李XX',
            createTime: '2020-05-15 16:40:57.296493',
            custId: '2200034902268',
            message: '你好啊',
            messageId: '1589531942002',
            projectId: '2020051401',
            projectName: '项目名称项目名称'
          },
          {
            commPersonId: '0000000001',
            commPersonName: '李XX',
            createTime: '2020-05-15 16:41:35.615126',
            custId: '2200034902268',
            message: '天香一双',
            messageId: '1589531980343',
            projectId: '2020051401',
            projectName: '项目名称项目名称'
          },
          {
            commPersonId: '0000000001',
            commPersonName: '李XX',
            createTime: '2020-05-15 16:42:25.013778',
            custId: '2200034902268',
            message: '无语啊',
            messageId: '1589532029740',
            projectId: '2020051401',
            projectName: '项目名称项目名称'
          },
          {
            commPersonId: '0000000001',
            commPersonName: '李XX',
            createTime: '2020-05-15 17:12:23.586023',
            custId: '2200034902268',
            message: '无1111语啊',
            messageId: '1589533828214',
            projectId: '2020051401',
            projectName: '项目名称项目名称'
          }
        ]
      })
    )
  },
  'POST /gw/wx_miniapp/QryProjectIntroduction.do'(req, res) {
    res.json(
      ENTSuccess({
        intro: [
          '中国民生银行成立于1996年1月12日，总部位于北京，是中国第一家主要由民营企业发起设立的全国性股份制商业银行，坚持"民营企业的银行、科技金融的银行、综合服务的银行"的战略定位。',
          '中国民生银行在内地和香港两地上市，股票代码"SH600016"及"HK01988"。',
          '英国《银行家》杂志2019年7月发布全球1000家银行排名， 中国民生银行位居第28位。',
          '美国《财富》杂志2019年7月发布世界500强企业排名，中国民生银行位居第232位。',
          '民生银行拥有雄厚的人才、信息、技术、网络和资金，以扶持战略性优质资源、资产为主要目标，与集团内租赁、基金、资管、境外投融资平台协同，搭建并完善为企业服务的投、融资平台，并打造货币市场、债券市场、股票市场和股权投资领域的投融资工具和产品体系，为客户提供多元化的金融解决方案，并提供最佳资金匹配方案。'
        ],
        file: 'byte,byte,byte'
      })
    )
  },
  'POST /gw/wx_miniapp/ContactUs.do'(req, res) {
    res.json(
      ENTSuccess({
        resultMap: {
          phone: '010-58560666',
          email: 'aaaaa@163.com',
          address: '北京市西城区西绒线胡同28号中国民生银行股份有限公司'
        },
        file: 'byte,byte,byte'
      })
    )
  },
  'POST /gw/wx_miniapp/QrySearchHistory.do'(req, res) {
    res.json(
      ENTSuccess({
        keyWordsList: [
          {
            searchTime: 1589529495342,
            keyWord: '资本市场'
          },
          {
            searchTime: 1589531298655,
            keyWord: '股权类'
          },
          {
            searchTime: 1589529495342,
            keyWord: '公司股权融资'
          },
          {
            searchTime: 1589531298655,
            keyWord: '民生银行1'
          },
          {
            searchTime: 1589531298655,
            keyWord: '民生银行2'
          },
          {
            searchTime: 1589531298655,
            keyWord: '民生银行3'
          },
          {
            searchTime: 1589531298655,
            keyWord: '民生银行4'
          }
        ]
      })
    )
  },
  'POST /gw/wx_miniapp/ClearSearchHistory.do'(req, res) {
    res.json(
      ENTSuccess({
        isSuccess: 1
      })
    )
  },
  'POST /gw/wx_miniapp/QryMsgByKeyWord.do'(req, res) {
    const resultList = [
      {
        projectName: '山西省国企混改E矿泉水公司控股权转让1',
        projectId: '001',
        projectType: '权益项目-标的项目（非房地产）',
        targetOrg: '适合机构1',
        region: '山西省'
      },
      {
        projectName: '山西省国企混改E矿泉水公司控股权转让2',
        projectId: '001',
        projectType: '权益项目-标的项目（非房地产）',
        targetOrg: '适合机构2',
        region: '陕西省'
      },
      {
        projectName: '山西省国企混改E矿泉水公司控股权转让3',
        projectId: '001',
        projectType: '权益项目-标的项目（非房地产）',
        targetOrg: '适合机构3',
        region: '江苏省'
      }
    ]

    res.json(
      ENTSuccess({
        pageNo: '1',
        pageSize: '10',
        total: 3,
        resultList
      })
    )
  },
  'POST /gw/wx_miniapp/PerWXLgnOutVerifyMsg.do'(req, res) {
    res.json(ENTSuccess({ checkSmsCodeFlag: '0' }))
  },
  'POST /gw/wx_miniapp/InvestFinanceCustInfoVertify.do'(req, res) {
    res.json(ENTSuccess({ checkCodeFlag: '0' }))
  }
}
